﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using QuanLyDiem.models;
namespace QuanLyDiem.Controllers
{
    class C_TaoLopHocPhan
    {
         public static void LoadDataSource(ComboBox comboBox, MonHoc value = null, Context db = null)
        {
            if (db == null) db = new Context();
            var Ky_hocs = db.ChuongTrinhDaoTaos.Select(p => p.Ky_hoc).Distinct().OrderBy(o=>o).ToList();
            comboBox.DataSource = Ky_hocs;
        }
    }
}
